<template>
 <view>
<view class="essential">
        <view class="information">
          <view class="essential_size">基本信息</view>
          <view class="formData">
            <formData
              :values="values"
              :fields="fields"
              :rules="rules"
              :borderBottom="true"
              ref="formDtata"
            ></formData>
          </view>
        </view>
      </view>
	    <view class="other">
        <view class="information">
			<view class="essential_size">资产情况</view>
			<view class="social">车辆</view>
			<u-radio-group v-model="values.property_json[0].value"  size='32rpx' >
			<u-radio 
			 shape="square"
				v-for="(item, index) in vehicleList" :key="index" 
				:name="item.name" label-size="28rpx"
				:disabled="item.disabled"
				:class="index%2 != 1?'radio ':''"
				class="radio_top"
			>
				{{item.name}}
			</u-radio>
		</u-radio-group>
		<view class="show"></view>
			<view class="social">房产</view>
			<u-radio-group v-model="values.property_json[1].value"  size='32rpx' >
			<u-radio 
				 shape="square"
				v-for="(item, index) in vehicleList" :key="index" 
				:name="item.name" label-size="28rpx"
				:disabled="item.disabled"
				:class="index%2 != 1?'radio ':''"
				class="radio_top"
			>
				{{item.name}}
			</u-radio>
		</u-radio-group>
		</view>
      </view>
      <view class="other">
        <view class="information">
			<view class="essential_size">其他</view>
			<view class="social">本地社保</view>
			<u-radio-group v-model="values.other_json[0].value"  size='32rpx' >
			<u-radio 
				 shape="square"
				v-for="(item, index) in localList" :key="index" 
				:name="item.name" label-size="28rpx"
				:disabled="item.disabled"
				:class="index%2 != 1?'radio ':''"
				class="radio_top"
			>
				{{item.name}}
			</u-radio>
		</u-radio-group>
		<view class="show"></view>
			<view class="social">公积金</view>
			<u-radio-group v-model="values.other_json[1].value" size='32rpx' >
			<u-radio 
				  shape="square"
				v-for="(item, index) in fundList" :key="index" 
				:name="item.name" label-size="28rpx"
				:disabled="item.disabled"
				:class="index%2 != 1?'radio ':''"
				class="radio_top"
			>
				{{item.name}}
			</u-radio>
		</u-radio-group>
		</view>
      </view>
        <view class="nextStep" @click="addPitchIndex">下一步</view>
 </view>
</template>

<script>
import { mapState, mapActions } from "vuex";
import formData from "./form/index.vue";
 export default {
   data () {
     return {

     }
   },
   components: {
formData
   },
   methods: {
    addPitchIndex(){
     let flag =this.$refs.formDtata.submit()
     if(flag){
this.$emit('addPitchIndex');
     }
        
    },
   },
   mounted() {

   },
   watch: {

   },
   computed: {
...mapState({
      values: (state) => state.MANAGEMENT.values,
      fields: (state) => state.MANAGEMENT.fields,
      rules: (state) => state.MANAGEMENT.rules,
	  localList:(state) => state.MANAGEMENT.localList,
	  fundList:(state) => state.MANAGEMENT.fundList,
	  vehicleList:(state) => state.MANAGEMENT.vehicleList,
    }),
   }
 }
</script>

<style scoped lang='scss'>
.essential {
  width: 686rpx;
  height: 690rpx;
  background: #ffffff;
  margin-left: 32rpx;
  margin-top: 160rpx;
  border-radius: 10rpx;
}
.information {
 padding-left: 32rpx;
}
.essential_size {
  color: #222223;
  font-size: 32rpx;
  padding-top: 34rpx;
}
.other {
  width: 686rpx;
  height: 580rpx;
  background: #ffffff;
  border-radius: 10rpx;
  margin-top: 32rpx;
  margin-left: 32rpx;
}
.social{
	font-size: 28rpx;
color: #90939D;
margin-top: 14rpx;
}
.radio{
	width: 370rpx !important;
}
.radio_top{
	margin-top: 32rpx;
}
.show{
	width: 624rpx;
height: 0px;
border: 2rpx solid #EEEEEE;
margin-top: 32rpx;
}
.nextStep{
	width: 686rpx;
		height: 100rpx;
		background: #E24D49;
		border-radius: 10rpx;
		font-size: 32rpx;
		color: #FFF;
		margin-top: 60rpx;
		display: flex;
		justify-content: center;
		align-items: center;
		margin-left: 32rpx;
}
</style>